// routes/articleRoutes.js
const express = require("express");
const router = express.Router();
const productController = require("../controllers/product");

router.get("/product", productController.list);
router.post("/product/add", productController.add);
router.post("/product/update", productController.update);
router.post("/product/del", productController.del);
router.post("/product/label/add", productController.addLabel);
router.post("/product/label/del", productController.delLabel);
router.post("/product/image/add", productController.uploadImage);

router.get("/getProductByPosition", productController.getProductByPosition);
router.get("/getProductByShopId", productController.getProductByShopId);
router.get("/getProductById", productController.getProductById);

module.exports = router;
